-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Argo CD should provide apiversion and kinds to 'helm template' command #7519
Conversation
Codecov Report
@@ Coverage Diff @@
## master #7519 +/- ##
==========================================
+ Coverage 41.38% 41.40% +0.01%
==========================================
Files 161 161
Lines 21618 21622 +4
==========================================
+ Hits 8947 8952 +5
Misses 11408 11408
+ Partials 1263 1262 -1
Continue to review full report at Codecov.
|
server/application/application.go
Outdated
@@ -313,7 +314,7 @@ func (s *Server) GetManifests(ctx context.Context, q *application.ApplicationMan | |||
return err | |||
} | |||
|
|||
apiGroups, err := s.kubectl.GetAPIGroups(config) | |||
apiGroups, err := s.kubectl.GetAPIResources(config, false, kubecache.NewNoopSettings()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Variable apiGroups
should be renamed to apiResources
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good point. renamed.
util/argo/argo.go
Outdated
func APIResourcesToStrings(resources []kube.APIResourceInfo, includeKinds bool) []string { | ||
resMap := map[string]bool{} | ||
for _, r := range resources { | ||
val := r.GroupVersionResource.GroupVersion().String() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think it will be better name it groupVersion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds good. renamed.
a590663
to
a802edd
Compare
1c5c49b
to
31ac554
Compare
go.mod
Outdated
) | ||
|
||
replace github.com/argoproj/gitops-engine => github.com/alexmt/gitops-engine v0.0.0-20211022180552-069d05c651a6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be from github.com/argoproj/gitops-engine, instead of a fork.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ops, thanks for catching it. Removed replace
and switched to latest github.com/argoproj/gitops-engine commit
@@ -47,7 +47,6 @@ core/v1/EnvVar | |||
core/v1/EnvVarSource | |||
core/v1/EphemeralContainer | |||
core/v1/EphemeralContainerCommon | |||
core/v1/EphemeralContainers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why EphemeralContainers
is removed from known_types?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This code is auto-generated. Looks like EphemeralContainers
type was removed from the v1.22 k8s client library.
…ommand Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
31ac554
to
6cc0bad
Compare
Thank you for review @mayzhang2000 . PTAL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…ommand (argoproj#7519) Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com> Signed-off-by: Denis Lavrushko <denis.lavrushko@iits-consulting.de>
Fix Gitea Ingress thanks to argoproj/argo-cd#7519
Signed-off-by: Alexander Matyushentsev AMatyushentsev@gmail.com
Closes #6351
PR changes ensures that Argo CD passes both api versions and api version kinds to
helm template
command during manifest generation.Depends on argoproj/gitops-engine#337